package pacman.objects;

import java.awt.Color;
import java.awt.Graphics;

/**
 * This class represents the floor object
 * @author Carlos Massera Filho
 */
public class Floor extends Static
{
  /**
   * Start the floor as a visible and not hitable object
   * @param posX Position X to insert a floor
   * @param posY Position Y to insert a floor
   */
  public Floor(float posX, float posY)
  {
    this.posX = posX;
    this.posY = posY;
    this.visible = true;
    this.passable = true;
  }
  
  /**
   * Draw the floor in the Graphic interface
   * @param g
   */
  public void render(Graphics g)
  {
    g.setColor(Color.BLACK);
    g.fillRect((int)(posX * getCellSize()), (int)(posY * getCellSize()), (int)getCellSize(), (int)getCellSize());
  }
}
